package nl.grol.yakshop.web.util;

import javax.jdo.PersistenceManager;

public class RequestContext {
    private PersistenceManager pm = null;
    private int readCounter = 0;
    private int writeCounter = 0;
    
    public RequestContext( PersistenceManager pm ) {
        this.pm = pm;
        this.readCounter = 0;
        this.writeCounter = 0;
    }

    public PersistenceManager getPersistanceManager() {
        return pm;
    }

    public int getReadCounter() {
        return readCounter;
    }

    public void incrementReadCounter() {
        this.readCounter++;
    }
    
    public int getWriteCounter() {
        return writeCounter;
    }
    public void incrementWriteCounter() {
        this.writeCounter++;
    }
    
    
}
